GdkWindow *window = gdk_gl_context_get_window (context);
GdkWin32Display *display = (GDK_WIN32_DISPLAY (gdk_gl_context_get_display (context)));
gboolean can_wait = display->hasWglOMLSyncControl;
+ cairo_rectangle_int_t whole_window;
- GDK_DRAW_CONTEXT_CLASS (gdk_x11_gl_context_parent_class)->end_frame (draw_context, painted, damage);
+ GDK_DRAW_CONTEXT_CLASS (gdk_win32_gl_context_parent_class)->end_frame (draw_context, painted, damage);
if (gdk_gl_context_get_shared_context (context))
return;
GdkGLContext *context = GDK_GL_CONTEXT (draw_context);
GdkWindow *window;
- GDK_DRAW_CONTEXT_CLASS (gdk_x11_gl_context_parent_class)->begin_frame (draw_context, update_area);
+ GDK_DRAW_CONTEXT_CLASS (gdk_win32_gl_context_parent_class)->begin_frame (draw_context, update_area);
if (gdk_gl_context_get_shared_context (context))
return;
static void
gdk_win32_gl_context_class_init (GdkWin32GLContextClass *klass)
{
- GdkGLContextClass *context_class = GDK_GL_CONTEXT_CLASS (klass);
+ GdkGLContextClass *gl_context_class = GDK_GL_CONTEXT_CLASS(klass);
+ GdkDrawContextClass *draw_context_class = GDK_DRAW_CONTEXT_CLASS(klass);
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
- context_class->begin_frame = gdk_win32_gl_context_begin_frame;
- context_class->end_frame = gdk_win32_gl_context_end_frame;
- context_class->realize = _gdk_win32_gl_context_realize;
+ gl_context_class->realize = gdk_win32_gl_context_realize;
+
+ draw_context_class->begin_frame = gdk_win32_gl_context_begin_frame;
+ draw_context_class->end_frame = gdk_win32_gl_context_end_frame;
gobject_class->dispose = _gdk_win32_gl_context_dispose;
}
if (impl->layered)
return FALSE;
+ /* FIXME: Possibly remove the following lines when we transition to GL
+ * drawing fully. This will probably mean that we won't
+ * be able to use layered windows, as layered windows seem
+ * to support only up to OpenGL 1.1, which is not enough for our
+ * needs here.
+ */
+
/* Non-GL windows are moved *after* repaint.
* We don't supply our own surface, return TRUE to make GDK create
* one by itself.
- */
+ *//*
if (!window->current_paint.use_gl)
- return TRUE;
+ return TRUE;*/
/* GL windows are moved *before* repaint (otherwise
* repainting doesn't work), but if there's no move queued up,
static void
gdk_win32_window_end_paint (GdkWindow *window)
{
+ /* FIXME: Possibly make gdk_win32_window_end_paint() a
+ * no-op stub, like what is done in Wayland, as
+ * the items here rely on layered window usage,
+ * when we transition to full GL drawing, as
+ * layered windows do not support enough GL
+ * for our needs here
+ */
GdkWindowImplWin32 *impl;
RECT window_rect;
HDC hdc;
impl = GDK_WINDOW_IMPL_WIN32 (window->impl);
/* GL windows are moved *before* repaint */
- if (window->current_paint.use_gl)
- return;
+ /*if (window->current_paint.use_gl)
+ return;*/
/* No move/resize is queued up, and we don't need to update
* the contents of a layered window, so return immediately.